from datetime import datetime
import time
import json
import snowflake.client
import requests
from django.test import TestCase

# Create your tests here.
# 测试雪花算法
s_id = snowflake.client.get_guid()
print(s_id)
# print("binary:", bin(s_id))
# # 10001001101110000111011010101000011010111
# print(datetime.now())
# time_now = datetime.now()
# formatted_now = time_now.strftime("%Y%m%d%H%M%S")
# print(formatted_now)

# 装饰器
# def outer(fun):
#     def inner():
#         t1 = time.time()
#         fun()
#         t2 = time.time()
#         the_time = t2 - t1
#         print(the_time)
#     return inner
#
# @outer
# def aa():
#     for i in range(100):
#         print("aa")
#
# aa()